package com.common.server.entity.user;

import com.baomidou.mybatisplus.annotation.*;
import com.common.server.entity.base.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;

/**
 * 用户
 *
 * @TableName user
 */
@EqualsAndHashCode(callSuper = true)
@TableName(value = "user_info")
@ApiModel(value = "用户信息")
@Data
public class UserInfo extends BaseEntity implements Serializable {

    /**
     * id
     */
    @ApiModelProperty(value = "用户id", required = false)
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 账号
     */
    @ApiModelProperty(value = "账号", required = false)
    private String userAccount;

    /**
     * 密码
     */
    @ApiModelProperty(value = "密码", required = false)
    private String userPassword;

    /**
     * 用户昵称
     */
    @ApiModelProperty(value = "用户昵称", required = false)
    private String userName;

    /**
     * 用户头像
     */
    @ApiModelProperty(value = "用户头像", required = false)
    private String userAvatar;

    /**
     * 用户简介
     */
    @ApiModelProperty(value = "用户简介", required = false)
    private String userProfile;

    /**
     * 用户角色(0-管理员, 1-普通用户, 2-被禁用)
     */
    @ApiModelProperty(value = "用户角色(0-管理员, 1-普通用户, 2-被禁用)", required = false)
    private String userRole;

    /**
     * 是否删除
     */
    @ApiModelProperty(value = "是否删除", required = false)
    @TableLogic
    private Integer isDeleted;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}